import { request } from '@/utils/request';
import { PageParams } from "@/api/model/pageParams";

export const page = async (params: PageParams) => {
    return request.post({
        url: '/foodType/page',
        data: params
    });
}
export const getOptions = async (id: string) => {
  return request.get({
      url: '/foodType/options'
  });
}

export const saveApi = async (data: any) => {
    return request.post({
        url: '/foodType/save',
        data
    });
}

export const deleteById = async (id: string) => {
    return request.get({
        url: `/foodType/delete/${id}`,
    });
}